﻿///////////////////////////////////////////////////////////////
//                                                           //
// Code from Arcanea Project.                                //
//                                                           //
// Please include this license part to every reproduction    //
//   of code.                                                //
//                                                           //
// This code is under Ms-RL license                          //
//                                                           //
// Please read futher information about the license,         //
//   the project (news and updates) and the                  //
//   contributors on the address :                           //
//     http://www.codeplex.com/Arcanea/                      //
//                                                           //
///////////////////////////////////////////////////////////////
using System;
using System.Collections.Generic;
//using System.Linq;
using System.Text;
using System.Reflection;
using log4net;

namespace Arcanea.NetworkEngine.Abstract.Engines
{
    /// <summary>
    /// Contrat que doit respecter l'engine de cryptage
    /// </summary>
    public abstract class ICryptageEngine
    {
        protected static readonly ILog logger = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);

        /// <summary>
        /// Crypte un tableau de byte
        /// </summary>
        /// <param name="arrayDecrypted">Tableau non crypté</param>
        /// <returns>Tableau de byte crypté</returns>
        public abstract byte[] Crypt(byte[] arrayDecrypted);

        /// <summary>
        /// Décrypte un tableau de byte
        /// </summary>
        /// <param name="arrayCrypted">Tableau crypté</param>
        /// <returns>Tableu non crypté</returns>
        public abstract byte[] Decrypt(byte[] arrayCrypted);

    }
}
